<form action="{:U('show_list')}" method="get">
	<!--  
	<div id="nav" class="mainnav_title">
		<ul>
			<if condition="$type eq 0"> <a class="on"
				href="__URL__/show_list?type=0&line_id={$line_id}">发起拼团订单</a> <a
				href="__URL__/show_list?type=1&line_id={$line_id}">报名拼团订单</a> <a
				href="__URL__/show_list?type=2&line_id={$line_id}">普通订单</a> </if>

			<if condition="$type eq 1"> <a
				href="__URL__/show_list?type=0&line_id={$line_id}">发起拼团订单</a> <a
				href="__URL__/show_list?type=1&line_id={$line_id}" class="on">报名拼团订单</a>
			<a href="__URL__/show_list?type=2&line_id={$line_id}">普通订单</a> </if>


			<if condition="$type eq 2"> <a
				href="__URL__/show_list?type=0&line_id={$line_id}">发起拼团订单</a> <a
				href="__URL__/show_list?type=1&line_id={$line_id}">报名拼团订单</a> <a
				href="__URL__/show_list?type=2&line_id={$line_id}" class="on">普通订单</a>
			</if>
		</ul>
	</div>
	-->

	<table class="search_table" width="100%">
		<tr>
			<td class="search">线路编号: <input id="lcode" type="text"
				class="input-text" name="lcode" value="{$get.lcode}" />
			</td>
			<td class="search">联系方式: <input id="phone" type="text"
				class="input-text" name="phone" value="{$get.phone}" /> <!-- 			<input -->
				<!-- 				type="submit" value="查询" class="button" /> -->
			</td>
			<td class="search">姓名: <input id="name" type="text"
				class="input-text" name="name" value="{$get.name}" />
			</td>

		</tr>
		<tr>
			<td class="search">订单号: <input id="orderid" type="text"
				class="input-text" name="orderid" value="{$get.orderid}" />
			</td>
			<td class="search">起始时间: <input name="strorderdate" type="text"
				id="strorderdate" value='' class="input-text calender" />
			</td>
			<td class="search">终止时间:<input name="endorderdate" type="text"
				id="endorderdate" value='' class="input-text calender" />
			</td>
		</tr>
		<tr>
			<td class="search">客服编号: <input id="assistcode" type="text"
				class="input-text" name="assistcode" value="{$get.assistcode}" />
			</td>
			<td class="search">订单状态: <select name="state" id="state">
					<option value="99"  <if condition="$get.state eq 99">selected="true"</if> >请选择</option>
					<option value="0" <if condition="$get.state eq 0">selected="true"</if> >未付款
					</option>
					<option value="1" <if condition="$get.state eq 1">selected="true"</if> >已付款
					</option>
					<option value="2" <if condition="$get.state eq 2">selected="true"</if> >已申请退款
					</option>
					<option value="3" <if condition="$get.state eq 3">selected="true"</if> >已退款
					</option>
					<option value="4" <if condition="$get.state eq 4">selected="true"</if> >已发团
					</option>
			</select>
			</td>
			<td class="search">产品类型: <select name="line_type" id="line_type">
					<option value=""<if condition="$get.line_type eq ''">selected="true"</if>>请选择
					</option>
					<option value="1"<if condition="$get.line_type eq 1">selected="true"</if>>包团
					</option>
					<option value="2"<if condition="$get.line_type eq 2">selected="true"</if>>纯玩
					</option>
					<option value="3"<if condition="$get.line_type eq 3">selected="true"</if>>常规
					</option>
					<option value="4"<if condition="$get.line_type eq 4">selected="true"</if>>自驾游
					</option>
					<option value="5"<if condition="$get.line_type eq 5">selected="true"</if>>团体策划
					</option>
					<option value="6"<if condition="$get.line_type eq 6">selected="true"</if>>其他
					</option>
			</select>
			</td>
		</tr>
		<tr>
			<td class="search">目的地: <select name="city" id="city">
					<option value="">请选择</option>
					<option value="0471"<if condition="$get.city eq '0471'">selected="true"</if>>呼和浩特
					</option>
					<option value="0470"<if condition="$get.city eq '0470'">selected="true"</if>>呼伦贝尔
					</option>
					<option value="0479"<if condition="$get.city eq '0479'">selected="true"</if>>锡林浩特
					</option>
					<option value="0479"<if condition="$get.city eq '0479'">selected="true"</if>>赤峰
					</option>
					<option value="0483"<if condition="$get.city eq '0483'">selected="true"</if>>额济纳
					</option>
					<option value="">其他</option>
			</select>
			</td>
			<td class="search">客源地: <input name="strorderdate" type="text"
				id="strorderdate" value='' class="input-text calender" />
			</td>
			<td><input type="submit" value="查询" class="button" /></td>
		</tr>

	</table>
</form>

<form name="myform" id="myform" action="{:U('LineTarget/order_target')}"
	method="post">
	<div class="table-list">
		<table cellspacing="1" cellpadding="1" width="100%">
			<thead>
				<tr style="background: #fff;">
					<!-- 					<th>订单ID</th> -->
					<th>订单号</th>
					<th>联系人</th>
					<th>线路名</th>
					<th>报名时间</th>
					<th>发团日期&人数&价格</th>
					<th>组团方式</th>
					<th>预付款</th>
					<th>总费用</th>
					<th>状态</th>
					<th>操作</th>
				</tr>
			</thead>

			<tbody id="content">
				<volist name="list" id="vo">
				<tr>
					<!-- 					<td>{$vo.id}</td> -->
					<td>{$vo.orderid}</td>
					<td>{$vo.name}<br>{$vo.phone}
					</td>
					<td style="width:270px;"><a href="__ROOT__/index.php/travel/detail/id/{$vo.line_id}" target="_blank">{$vo.names}</a></td>
					<td>{$vo.orderdate}</td>
					<td>{$vo.startdate}<br>成人{$vo.pnumber}/ 每人￥{$vo.pmoney}元<br>儿童{$vo.cnumber}/每人￥{$vo.cmoney}元
						<br>
					</td>

					<td><if condition="$vo.line_type eq '1'">包团自由行 </if>
						 <if condition="$vo.line_type eq '2'" >纯玩团 </if>
						 <if condition="$vo.line_type eq '3'" >常规团 </if>
						 <if condition="$vo.line_type eq '4'" >团队策划 </if>
							</td>
					<td>{$vo.remoney}</td>
					<td>￥{$vo.price}元</td>
					<td><if condition="$vo.state eq '0'">待付款 <elseif
							condition="$vo.state eq '1'" />已付款 <elseif
							condition="$vo.state eq '2'" />已申请退款 <elseif
							condition="$vo.state eq '3'" />已退款<elseif
							condition="$vo.state eq '4'" />已发团 <elseif
							condition="$vo.state eq '6'" />已结束 <elseif
							condition="$vo.state eq '7'" />已取消 </if></td>
					<td><a
						href="{:U('lineorder/select_win',array('orderid'=>$vo['orderid']))}">查看</a>
						<if condition="$vo.state eq '1'">&nbsp;|&nbsp;<a
							href="{:U('lineorder/set_status',array('id'=>$vo['id']))}">发团</a>
						<elseif condition="$vo.state eq '2'" />&nbsp;|&nbsp;<a
							href="{:U('lineorder/select_win',array('orderid'=>$vo['orderid']))}">退款</a>
						<elseif condition="$vo.o_status eq '7'" /> </if> &nbsp; &nbsp; <a
						href="javascript:delorder('{$vo['orderid']}');">删除</a></td>
				</tr>
				</volist>
			</tbody>

		</table>
		<input type="hidden" name="base_pos" value="{~echo MODULE_NAME}">
	</div>
	<div class="btn"></div>
</form>
<form name="delform" id="delform" action="{:U('lineorder/delorder')}"
	method="get">
	<input type="hidden" id="delorderid" name="delorderid">
</form>
<div class="page">{$page}</div>
<script language="javascript">
    
    function select_win(orderid){
        art.dialog.open('{:U('select_win')}?orderid='+orderid,{
		title:'订单信息',
		width:720,
		height:550,
		lock:'true'
		});
    }
    
    function edit_win(id){
        art.dialog.open('{:U('edit_win')}?id='+id,{
		title:'编辑订单',
		width:640,
		height:480,
		lock:'true'
		});
    }
    function delorder(orderid){
    	$('#delorderid').val(orderid);
    	art.dialog.confirm("您确定要删除此订单吗？", function(){$('#delform').trigger("submit")});
    }
	
</script>